import { createApp } from 'vue'
import App from './App.vue'
import router from './router'

import { IonicVue } from '@ionic/vue'

/* Core CSS required for Ionic components to work properly */
import '@ionic/vue/css/core.css'

/* Basic CSS for apps built with Ionic */
import '@ionic/vue/css/normalize.css'
import '@ionic/vue/css/structure.css'
import '@ionic/vue/css/typography.css'

/* Optional CSS utils that can be commented out */
import '@ionic/vue/css/padding.css'
import '@ionic/vue/css/float-elements.css'
import '@ionic/vue/css/text-alignment.css'
import '@ionic/vue/css/text-transformation.css'
import '@ionic/vue/css/flex-utils.css'
import '@ionic/vue/css/display.css'

/**
 * Ionic Dark Mode
 * -----------------------------------------------------
 * For more info, please see:
 * https://ionicframework.com/docs/theming/dark-mode
 */

/* @import '@ionic/vue/css/palettes/dark.always.css'; */
/* @import '@ionic/vue/css/palettes/dark.class.css'; */
import '@ionic/vue/css/palettes/dark.system.css'

//初始化esri的apikey
import esriConfig from '@arcgis/core/config.js'
esriConfig.apiKey =
  'AAPT3NKHt6i2urmWtqOuugvr9YRNB4XSo1vrkVMdHWXAf4_C3tYuT1cqk9rtXdNqsOF7_YRrUHAQG0K9JtWddhhzAaRklMYbjV9Em8Tzqs-5lHds682hGpJ2u8i8-7CeFecs0s2nb45FewELNRllLXZ3YT4mwwS5X1fjvZ5zm7Uv2YyHxyv1JkIzrkxTkWQ54LgNKc5zWQWWRzfN3BfrH5UY0ib7aeqg285xg3avuAMYc5lixDiafEjr3y1z9zxGgJjX'
//初始化esri语言
import * as intl from '@arcgis/core/intl.js'
intl.setLocale('zh-CN')

/* Theme variables */
import './theme/variables.css'

const app = createApp(App).use(IonicVue).use(router)

router.isReady().then(() => {
  app.mount('#app')
})
